home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / SourceCode / MiscKit1.7.1 / MiscKit / Palettes / MiscCircularSlider / README < prev   
Encoding:
Text File  |  1995-07-06  |  5.5 KB  |  119 lines

  1. #
  2. #     Filename: README
  3. #     Created : Mon Sep  6 16:44:31 1993
  4. #     Author  : Don Yacktman <Don_Yacktman@byu.edu>
  5. #              Vince DeMarco <vince@whatnxt.cuc.ab.ca>
  6. #
  7.  
  8. This is a rewrite of the circular slider classes:  Vince's CircularSlider
  9. palette and Don's RotationSlider palette.  It provides more options than
  10. either palette had by itself and fixes a few minor bugs which were mostly
  11. seen in the rendering.  (And probably introduces some new bugs... :*)
  12.  
  13. If you make any interesting subclasses please let us about them; we'd
  14. love to add any useful subclasses in the MiscKit!
  15.  
  16. Note that Don is the official maintainer of this palette; he is the one
  17. who performed the merge of the two palettes and knows the new code best.
  18. (In many ways it is very different from either of the two original
  19. classes, as it turns out.)
  20.  
  21. -----
  22. -Don Yacktman
  23. Don_Yacktman@byu.edu
  24.  
  25. vince demarco
  26. vince@whatnxt.cuc.ab.ca
  27.  
  28.  
  29. Carl Lindberg  Wed Apr 19 22:09:01 EDT 1995
  30.  
  31. Added support for borders - the control for them in the inspector
  32.   works now.  I also added a couple of more border types in there...
  33.   These are controlled by a new instance var, 'borderType'.  The
  34.   methods -setBezeled and -setBordered no longer have any affect;
  35.   use -setBorderType instead.  It might be nice to have -setBezeled
  36.   call -setBorderType:MISC_CSBEZEL, etc., but I haven't done that.
  37.  
  38. Added support for background color, settable in a color well.  If
  39.   you want a transparent background, set this color to be transparent.
  40.   You can set semi-transparent background colors, as well.  (This
  41.   required drawing border and background color to an NXImage, then
  42.   compositing that, instead of directly drawing to the view.)  If
  43.   'hidden' is checked, the only thing drawn will be the background
  44.   color.
  45.   **NOTE** There doesn't appear to be a way in IB's preferences to
  46.   make the opacity slider (for alpha) appear in the color panel.
  47.   If it is not there, you can't set a non-opaque color--it strips
  48.   alpha from any color it gives out, even if you click one of those
  49.   saved colors at the bottom.  Since this prevented setting a
  50.   slider to have a transparent background, the inspector's -init method
  51.   will now force the opacity slider to appear, allowing alpha to be
  52.   put in a color.  Just so it's known we are doing this. :-)
  53.  
  54. Added 'Jumps to mouse click' option in inspector.  You could already
  55.   do this in code, just not in the inspector.  You also can now set the
  56.   slider-style one to NOT jump to mouse click, though this makes
  57.   little sense.
  58.  
  59. Fixed bug in boundary checking.  It used to depend on the normal values
  60.   going from 0-360.  You can now set them to whatever you want.
  61.  
  62. Fixed bug when view was taller than it was wide.  If you clicked near the
  63.   bottom (where the slider appeared to be), it thought you clicked
  64.   near the top and wouldn't do anything.  If you clicked in the blank
  65.   area around the top, well, THEN you could control the slider.  Only
  66.   a problem when view was flipped.
  67.  
  68. Changed a couple of the pswrap functions.  The shuttlewheel-style now
  69.   figures its knob placement based on the circle center, radius, and
  70.   sliderPathWidth.  It used to use some other method that assumed 0,0
  71.   as the origin, which is not always true with borders.  The pswrap to
  72.   draw the slider-style knob now draws it in the lower left corner,
  73.   allowing the cached image to be exactly the size of the knob.  This
  74.   in turn allows for more precise placement.  Before, there used to
  75.   be some glitchiness on larger sliders of the knob going outside the
  76.   slider path, leaving some stray pixels.  You now need a ridiculously
  77.   big slider to have this happen.
  78.  
  79. Reorganized the code to something approaching sanity.  This palette
  80.   was originally a merging of two separate palettes, and the merging
  81.   wasn't quite seamless yet.  Now the drawing goes something like this:
  82.  
  83.     -drawSelf:inView:    Draws the border and background color, sets
  84.                          a couple of instance vars, and
  85.                          calls -drawBarInside::
  86.     -drawBarInside:      Draws the background of the slider itself,
  87.                          either the slider path or outline circles,
  88.                          and calls -drawKnob:
  89.     -drawKnob:           Draws the piepiece/line/knob.
  90.                          
  91.   Well, it makes sense to me anyways :-)  There isn't any duplicate
  92.   drawing code anymore.
  93.   Various other things were tweaked along the way, mostly places where
  94.   0,0 was assumed as the origin, which changed with borders.
  95.   
  96.  
  97. Carl Lindberg Mon Jun 12 00:36:31 EDT 1995
  98.  
  99. Added support for allowing specification of where the slider
  100.   "starts" at, that is, the angle at which the minValue is shown.
  101.   Previously, it was always on the right, except for the pie-style,
  102.   which was at the top.  The value specified is an angle from 0-360,
  103.   with 0 being on the right hand side as before.  A value of 90 will
  104.   put the start at the top, 270 on the bottom.  It would have actually
  105.   been nice to have a circular slider set this value on the inspector
  106.   panel, but I didn't think there was room.  It's not completely
  107.   obvious as it is, but I guess it'll do.
  108.  
  109. Added support for specifying which direction values increase in,
  110.   either clockwise or counterclockwise.  Previously, it was always
  111.   counterclockwise, except for the pie-style.  Change this with
  112.   the 'Goes clockwise' option; if not checked, the slider goes
  113.   counterclockwise.  Again, not the best way of specifying this,
  114.   but it was the best way to fit it into the inspector.
  115.  
  116. Modified the pie-style pswrap a bit to accomodate the above
  117.   modifications.  The pie-style slider used to give incorrect
  118.   values, this seems to have been fixed by the above mods.
  119.